package com.itheima.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.itheima.pojo.Category;
import com.itheima.pojo.Dish;
import com.itheima.pojo.Result;
import org.springframework.transaction.annotation.Transactional;
import org.springframework.web.bind.annotation.RequestBody;

public interface DishService extends IService<Dish> {

    //添加
    Result add(@RequestBody Dish dish);

    //菜品分页查询
    Result page(String name, Integer page, Integer pageSize);



    Result getid(String id);

    @Transactional
    Result delect(String ids);

    @Transactional
    Result update(int status, String ids);

    @Transactional
    Result updatee(@RequestBody Dish dish);

    @Transactional
    Result getByCategoryId(String categoryId);


    Result checkAll(String categoryId, String status);
}
